set(CMAKE_POSITION_INDEPENDENT_CODE ON)
# 创建静态库
add_library(kvcache_memorypool STATIC
    src/MemoryPool.cpp
    src/LruManager.cpp
)

# 公开头文件目录
target_include_directories(kvcache_memorypool PUBLIC
    ${SRC_DIR}/include
    ${COMMON_DIR}/include
)

target_include_directories(kvcache_memorypool PUBLIC include)
target_include_directories(kvcache_memorypool PRIVATE ${pybind11_INCLUDE_DIRS})

if(DEVICE STREQUAL "GPU")
    target_include_directories(kvcache_memorypool PUBLIC ${CUDA_INC_DIR})
    target_link_libraries(kvcache_memorypool ${CUDA_LIBRARIES})
endif()


